<?php


namespace app\community\oauth2\Entities;


use DateTimeImmutable;
use League\OAuth2\Server\Entities\AccessTokenEntityInterface;
use League\OAuth2\Server\Entities\RefreshTokenEntityInterface;

class RefreshTokenEntity implements RefreshTokenEntityInterface
{

    protected string $Identifier;
    protected DateTimeImmutable $ExpiryDateTime;
    protected AccessTokenEntityInterface $accessToken;

    public function getIdentifier()
    {
        // TODO: Implement getIdentifier() method.
        return $this->Identifier;
    }

    public function setIdentifier($identifier)
    {
        // TODO: Implement setIdentifier() method.
        $this->Identifier = $identifier;
        return $this;
    }

    public function getExpiryDateTime(): DateTimeImmutable
    {
        // TODO: Implement getExpiryDateTime() method.
        return $this->ExpiryDateTime;
    }

    public function setExpiryDateTime(DateTimeImmutable $dateTime): static
    {
        // TODO: Implement setExpiryDateTime() method.
        $this->ExpiryDateTime = $dateTime;
        return $this;
    }

    public function setAccessToken(AccessTokenEntityInterface $accessToken): static
    {
        // TODO: Implement setAccessToken() method.
        $this->accessToken = $accessToken;
        return $this;
    }

    public function getAccessToken(): AccessTokenEntityInterface
    {
        // TODO: Implement getAccessToken() method.
        return $this->accessToken;
    }
}